extends Button


func _ready() -> void:
	mouse_entered.connect(on_mouse_entered)
	mouse_exited.connect(on_mouse_exited)
	connect("button_down", on_pressed)
	
func _process(delta: float) -> void:
	pivot_offset = Vector2(size.x / 2, size.y / 2)

func on_mouse_entered():
	$HoverAnimation.play("hover")
 
func on_mouse_exited():
	$HoverAnimation.play_backwards("hover")

func on_pressed():
	$ClickAnimation.play("click")
